<template>
  <el-row :gutter="20">
    <el-col :span="6" v-for="(item, i) in list" :key="item.id">
      <div class="grid-content bg-purple">
        <i :style="{ color: arr[i] }" class="iconfont" :class="item.icon"></i>
        <div>
          <h4>{{ item.text }}</h4>
          <p>{{ item.num }}</p>
        </div>
      </div>
    </el-col>
  </el-row>
</template>

<script>
export default {
  props: {
    arr: {
      type: Array,
      default: () => []
    },
    list: {
      type: Array,
      default: () => []
    }
  }
}
</script>

<style lang="less" scoped>
.el-row {
  margin-bottom: 20px;
  &:last-child {
    margin-bottom: 0;
  }
}
.el-col {
  border-radius: 4px;
}
.bg-purple {
  background-color: #fff;
  display: flex;
  justify-content: space-around;
  i {
    font-size: 40px;
    padding-right: 30px;
  }
  > div {
    h4 {
      text-align: center;
      color: #999;
    }
    p {
      color: #022;
      font-size: 18px;
    }
  }
}
.grid-content {
  border-radius: 4px;
  min-height: 36px;
}
</style>
